-
Notifications
You must be signed in to change notification settings - Fork 399
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add tests to verify incoming event type handler works #269
Add tests to verify incoming event type handler works #269
Conversation
Codecov Report
@@ Coverage Diff @@
## master #269 +/- ##
===========================================
+ Coverage 62.24% 72.48% +10.24%
===========================================
Files 7 7
Lines 498 498
Branches 138 138
===========================================
+ Hits 310 361 +51
+ Misses 163 105 -58
- Partials 25 32 +7
Continue to review full report at Codecov.
|
I've added more patterns in the second commit. The test coverage has been much improved 🙌
|
respond: noop, | ||
ack: noop, | ||
}, | ||
// TODO: https://github.com/slackapi/bolt/issues/263 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@shanedewael How about merging this PR before #276 and removing these comments out to verify your change works?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes this is a good idea!
app.action({ callback_id: 'message_action_callback_id' }, ({ }) => { actionFn(); }) | ||
app.action({ callback_id: 'interactive_message_callback_id' }, ({ }) => { actionFn(); }) | ||
app.action({ callback_id: 'dialog_submission_callback_id' }, ({ }) => { actionFn(); }) | ||
app.view('view_callback_id', ({ }) => { viewFn(); }) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we add one for view_cancel
? I can do this when we merge this before my branch lands.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@shanedewael yes, we need to have it. I haven't added the one commented out yet as we didn't decide the design at that time.
Summary
This pull request adds a new test which verifies if handling incoming events works as expected. As you can see, Bolt now accepts
view_submission
added by #261 while it cannot handleview_closed
yet.Requirements (place an
x
in each[ ]
)